perm filename DATIME.POX[POX,WD]1 blob
sn#364648 filedate 1978-06-27 generic text, type T, neo UTF8
\|\\; Define Brick Character
\;
\M0FIX25;\; fixed font
\⊂'000040;\; VERREM - REM's syntax for defining macros with args
\⊂'000400;\; VERRHT - modified way to pass args with nest chars
\;
\@NUMER.POX[POX,WD];\; read in numeric macros
\; Macro to expand month number (decimal string) into month name
\;
\8MONTHNAME(NSTR)[\!MONTH⊗NSTR⊗;]\;
\ ;\∞MONTH1[JANUARY]\∞MONTH2[FEBRUARY]\∞MONTH3[MARCH]\∞MONTH4[APRIL]\;
\ ;\∞MONTH5[MAY]\∞MONTH6[JUNE]\∞MONTH7[JULY]\∞MONTH8[AUGUST]\;
\ ;\∞MONTH9[SEPTEMBER]\∞MONTH10[OCTOBER]\∞MONTH11[NOVEMBER]\;
\ ;\∞MONTH12[DECEMBER]\;
\;
\;
\∞DAY[\N extract day from date and time in ac
\ ;\P\N save ac
\ ;\L=-18;\N peel off date with lsh
\ ;\%=31;\N get day of month
\ ;\+=1;\N add 1 to normalize
\ ;\D∀\N convert to string
\ ;\p]\; restore ac
\;
\∞MONTH[\N extract month from date and time in ac
\ ;\P\N save ac
\ ;\L=-18;\N peel off date with lsh
\ ;\/=31;\N convert it to months
\ ;\%=12;\N get month of year
\ ;\+=1;\N add 1 to normalize
\ ;\!MONTHNAME(\D∀);\N convert to month name
\ ;\p]\; restore ac
\;
\∞YEAR[\N extract year from date and time in ac
\ ;\P\N save ac
\ ;\L=-18;\N peel off date with lsh
\ ;\/=372;\N convert to years
\ ;\+=1964;\N in Gregorian cal
\ ;\D∀\N convert to string
\ ;\p]\; restore ac
\;
\∞SECOND[\N extract second from date and time in ac
\ ;\P\N save ac
\ ;\∧'777777;\N pull out time in seconds
\ ;\%=60;\N find no of seconds after hour
\ ;\D∀\N convert to string
\ ;\p]\; restore ac
\;
\∞MINUTE[\N extract minute from date and time in ac
\ ;\P\N save ac
\ ;\∧'777777;\N pull out time in seconds
\ ;\/=60;\N convert to minutes
\ ;\%=60;\N find no of minutes after hour
\ ;\D∀\N convert to string
\ ;\p]\; restore ac
\;
\∞HOUR[\N extract hour from date and time in ac
\ ;\P\N save ac
\ ;\∧'777777;\N pull out time in seconds
\ ;\/=3600;\N find the hour
\ ;\D∀\N convert to string
\ ;\p]\; restore ac
\;
\∞SYSEDAYTIMEFORM[\N convert REM date and time to system form
\ ;\Q0\N save reg 0
\ ;\P\N push date and time
\ ;\∧'777777000000;\N extract date
\ ;\→0\N save in reg 0
\ ;\p\N restore date and time
\ ;\∧'777777;\N pull out time in minutes
\ ;\*=60;\N convert to seconds
\ ;\∨0\N or in contents of reg 0
\ ;\q0]\; restore reg 0
\;
\;\u'400101;\;
\∃∀\; date and time to ac
\!SYSEDAYTIMEFORM;
\!EVAL((\∞)(FILDA[)\!DAY;(]));\; day last edited
\!EVAL((\∞)(FILMO[)\!MONTH;(]));\; month last edited
\!EVAL((\∞)(FILYR[)\!YEAR;(]));\; year last edited
\!EVAL((\∞)(FILMIN[)\!MINUTE;(]));\; minute last edited
\!EVAL((\∞)(FILHR[)\!HOUR;(]));\; hour last edited
\;
\; Create Date and Time Overlay for use in EVERYPAGE Macro
\;
\oDATIM{0\!FILDA; \!FILMO; \!FILYR; \!FILHR;:\!FILMIN;}\;
\;